package geor.model;

import geor.app.R;
import android.content.ContentValues;
import android.content.Context;
import android.database.Cursor;
import lib.model.Helper;

public class ReceitaHelper extends Helper {
	
	private static final String TABLE_NAME = "conta";
	
	public ReceitaHelper(Context context) {
		super(context);
	}

	@Override
	public long create(ContentValues values) {
		return create(TABLE_NAME, "descricao", values);
	}

	@Override
	public Cursor read(String id) {
		String[] params = {id};
		return getReadableDatabase().rawQuery(resources.getString(R.string.sql_conta_read), params);
	}
	
	
	public Cursor contas_Mes(String data) {
		String[] param = {data} ;
		return getReadableDatabase().rawQuery(resources.getString(R.string.sql_compras_no_mês), param);
	}

	@Override
	public void update(String id, ContentValues values) {
		
	}

	@Override
	public boolean delete(String id) {
		return false;
	}

	@Override
	public Cursor readAll(String whereClause, String[] whereArgs) {
		return null;
	}

	@Override
	public Cursor contas_Pagar(String data) {
		String[] param = {data} ;
		return getReadableDatabase().rawQuery(resources.getString(R.string.sql_compras_pagar), param);
	}

}
